#!/bin/sh

#Shadowsocks
iptables -t nat -N SHADOWSOCKS
iptables -t nat -A SHADOWSOCKS -p tcp -j REDIRECT --to-ports 8888
#blocked ip
#twitter
iptables -t nat -A PREROUTING -p tcp -d 199.59.148.0/22 -j SHADOWSOCKS
iptables -t nat -A PREROUTING -p tcp -d 199.16.156.0/22 -j SHADOWSOCKS
#nytimes
iptables -t nat -A PREROUTING -p tcp -d 170.149.168.130 -j SHADOWSOCKS
iptables -t nat -A PREROUTING -p tcp -d 170.149.172.130 -j SHADOWSOCKS

ss-redir -c /etc/915.json -f /var/run/shadowsocks-redir.pid